package org.example.service.managebackend.module.user.service;

import org.example.service.managebackend.module.user.dao.UserDao;
import org.example.service.managebackend.module.user.domain.dto.LoginFormDTO;
import org.example.service.managebackend.module.user.domain.dto.UserDTO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class LoginService {

    @Autowired
    private UserDao userDao;

    public String login(LoginFormDTO loginForm) {
        UserDTO userInfo = userDao.login(loginForm.getUsername(), loginForm.getPassword());
        if (userInfo == null) {
            return null;
        }

        return "abc";
    }
}
